﻿<%@ WebHandler Language="C#" Class="ReplyMessage" %>

using System;
using System.Web;

public class ReplyMessage : IHttpHandler {
    public void ProcessRequest (HttpContext context) {
        UserHelper u = new UserHelper();
        context.Response.ContentType = "text/plain";
        int ID =Convert.ToInt32(context.Request["ID"]);
        try
        {
            if (u.ContentForID(ID) != null)
                context.Response.Write(u.ContentForID(ID));
                
        }
        catch
        {
            context.Response.Write(0); 
        }
    }
 
    public bool IsReusable {
        get {
            return false;
        }
    }

}